package top.appx.easysql;

import top.appx.easysql.ex.EasySqlException;

import java.sql.SQLException;

/**
 * Created by 燎火 on 2015/10/11.
 */
public class MySqlDBHelper extends BaseDBHelper {

    private String url;
    private String user;
    private String password;
    public MySqlDBHelper(String url,String user,String password){
        this.url = url;
        this.user = user;
        this.password = password;
    }

    @Override
    public BaseDatabase createDataBase() {
        try {
            return DBFactory.createMySqlDatabase(url, user, password);
        }catch (SQLException e){
            throw new EasySqlException(e);
        }
    }
}
